package kubayaxi.video.client.controller;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import kubayaxi.video.client.service.IDownloadRecordService;
import kubayaxi.video.mybatis.customize.model.downloadRecord.dto.AddRecordDTO;
import kubayaxi.video.service.base.common.request.BaseRequest;
import kubayaxi.video.service.base.common.response.ResponseResult;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
@RequestMapping("/client/downloadRecord")
@Api(tags = "客户端【下载视频记录】")
public class DownloadRecordController {
    @Resource
    private IDownloadRecordService downloadRecordService;

    @ApiOperation("添加下载视频记录")
    @PostMapping("/addRecord")
    public ResponseResult addRecord(@RequestBody BaseRequest<AddRecordDTO> dto){
        downloadRecordService.addRecord(dto);
        return ResponseResult.success();
    }

}
